package com.lqk.facade;

/**
 * @author lqk
 * @date 2021/12/6 18:21
 */
public class Stereo {
    private Stereo(){

    }
    // 使用单例模式，静态内部类
    private static class StereoInstance{
        private static final Stereo INSTANCE = new Stereo();
    }

    // 提供一个静态的公有方法，直接返回 SingletonInstance.INSTANCE
    public static Stereo getInstance(){
        return Stereo.StereoInstance.INSTANCE;
    }

    public void on(){
        System.out.println(" Stereo on ");
    }
    public void off(){
        System.out.println(" Stereo off ");
    }

    public void up(){
        System.out.println(" Stereo up ");
    }

    public void down(){
        System.out.println(" Stereo down ");
    }
}
